<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>Document</title>
    <link rel="stylesheet" href="../css/H-ui.reset.css">
    <link rel="stylesheet" href="../css/H-ui.min.css">
    <link rel="stylesheet" href="../css/H-ui.ie.css">
    <link rel="stylesheet" href="../css/page-css/page-home.css">
    <style type="text/css">
        body {
            background-color: transparent;
        }

        #allmap {
            width: 100%;
            height: 100%;
            overflow: hidden;
            margin: 0;
            font-family: "微软雅黑";
        }

        .menuTree {
            margin-left: 0px;
        }

        /* .menuTree >.tree-children>ul{
            display: block;
        } */

        .menuTree div {
            padding-left: 1px;
        }

        .menuTree div ul {
            overflow: hidden;
            display: block;
            height: auto;
            margin: 0;
        }

        .menuTree span {
            display: block;
            height: 20px;
            line-height: 25px;
            padding-left: 5px;
            margin: 1px 0;
            cursor: pointer;
            border-bottom: 1px solid rgb(90, 152, 247);
            color: #fff;
        }

        .menuTree span:hover {
            background-color: rgba(14, 144, 209, 0.5);
            color: #fff;
        }

        .menuTree a {
            color: #fff;
            text-decoration: none;
            display: block;
        }

        .menuTree a:hover {
            color: #06F;
        }

        .menuTree span {
            height: 30px;
        }

        .tree-not-children {
            margin-left: 30px;
        }
    </style>
</head>

<body>
    <div class="long-ji-main-content">
        <div class="main-content-left f-l w-300 pos-r ">
            <div class="arrow-t-l arrow-t"></div>
            <div class="arrow-t-r arrow-t"></div>
            <div class="arrow-b-l arrow-t"></div>
            <div class="arrow-b-r arrow-t"></div>
            <div class="main-content-left-nav">
                <div class="left-nav-search pos-r">
                    <input type="text" placeholder="站点搜索" class="input-text">
                    <img src="../images/system/search-icon.png" alt="" class="pos-a">
                </div>
                <div class="main-tree">

                    <div id="menuTree" class="menuTree"></div>

                </div>
            </div>

        </div>
        <div class="main-content-right f-l ml-20 main-common">
            <div id="allmap"></div>
        </div>
    </div>

    <script src="https://cdn.bootcss.com/jquery/3.2.0/jquery.min.js"></script>
    <script src="../js/page-js/groupTree.js"></script>
    <script type="text/javascript" src="http://api.map.baidu.com/api?v=2.0&ak=F33c961db25da2382848954e9eb968bb"></script>
    <script>
        $(function () {
            setWindowHeight();
            function setWindowHeight() {
                var height = $(window).height();
                var width = $(window).width();
                $('.main-content-right,.main-content-left-nav').css({
                    height: height - 20,
                    overflow: 'auto'
                })
                $('.main-content-right').css({
                    width: width - 320
                })
            }
            $(window).resize(function () {
                setWindowHeight();
            })

            // 百度地图API功能
            var map = new BMap.Map("allmap");            // 创建Map实例
            map.centerAndZoom(new BMap.Point(116.404, 39.915), 11);
            var local = new BMap.LocalSearch(map, {
                renderOptions: { map: map, autoViewport: true }
            });

            local.searchNearby("小吃", "前门");


            var json = [{
                name: "总站点",
                userLevel: "",
                children: [
                    {
                        name: "国外",
                        userLevel: "",
                        children: [
                            {
                                name: "国外国家1",
                                userLevel: "",
                                children: [
                                    {
                                        name: "站点1",
                                        userLevel: "",
                                        url:''
                                    },
                                    {
                                        name: "站点2",
                                        userLevel: "",
                                        url:''
                                    }
                                ]
                            },
                            {
                                name: "国外国家2",
                                userLevel: "",
                            }
                        ]
                    }
                ]
            }]

            showTree.tree(json)
        })


    </script>


</body>

</html>